package com.ruoyi.project.xkx.order.controller;

import com.ruoyi.framework.web.domain.AjaxResult;
import com.ruoyi.project.xkx.order.domain.OrderWay;
import com.ruoyi.project.xkx.order.service.OrderWayService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
@RequestMapping("/order/orderWay")
public class OrderWayController {
    @Autowired
    private OrderWayService orderWayService;

    /**
     * 获取所有订单支付方式
     * @return
     */
    @GetMapping("/getAllOrderWay")
    public AjaxResult getAllOrderWay(){
        List<OrderWay> result = orderWayService.list();
        return AjaxResult.success(result);
    }
}
